home *** CD-ROM | disk | FTP | other *** search
- /*flame 0.9
- **by Kyle Ellrott
- **garage@wave.net
- **11/20/96
- **
- **Some times the beast takes on a life of it's own...
- ** - What do you want to do to the world?
- ** - Burn it. Burn it all.
- */
-
- #define noSpeedUp 1
- #define lowRes2 2
- #define lowRes4 3
-
- typedef struct IndexNum{
- unsigned char ctabNum;
- }IndexNum;
-
- typedef IndexNum IndexArray[1];
-
- typedef struct Flame{
- Ptr baseAddr; //The work area
- Rect bounds; //The size
- char speedUp; //How big are the pixels
- short topLine; //The highest point of the flame
- long rowBytes; //The number of bytes per row
- unsigned char fColSize; //How many spots are in the next array
- IndexArray flameColors; //How do these colors look in the pixmap
- }Flame;
-
- typedef Flame *FlamePtr;
-
-
- OSErr SetUpFlames(CTabHandle flamePalette, CTabHandle destPalette,
- Rect *bounds, char speed, FlamePtr *theFlame);
-
- void KillFlames(FlamePtr *theFlame);
-
- void ChuckInFire(short x, short y, PixMapPtr victim, FlamePtr theFlame);
-
- void Spark(short x, short y, unsigned char heat, FlamePtr theFlame);
-
- void SetUpBurn(unsigned char odds, unsigned char max, unsigned char min, FlamePtr theFlame);
-
- void Burn (FlamePtr theFlame, unsigned char takeOff, Boolean fuzz);
-
- void CopyFlame(short x, short y, FlamePtr theFlame, PixMapPtr dest);
-
- void MaskFlame(short x, short y, FlamePtr theFlame, PixMapPtr dest);